package cn.calin.day05.demo04;

public class Demo04MethdOverload {
    public static void main(String[] args) {
        byte a=10;
        byte b=20;
        System.out.println(sum(a,b));
        System.out.println(sum((short) 20,(short) 21));
        System.out.println(sum(10l,10l));
    }

    public static boolean sum(byte a,byte b){
        boolean same;
        if(a==b){
            same=true;
        }else {
            same=false;
        }
        return same;
    }
    public static boolean sum(long a,long b){
//        boolean same= a==b?a:b;
//
//        return same;
        boolean same;
        if(a==b){
            same=true;
        }else {
            same=false;
        }
        return same;
    }
    public static boolean sum(short a,short b){
        boolean same;
        if(a==b){
            return true;
        }else{
            return false;
        }

    }
    public static boolean sum(int a,int b){


        return a==b;
    }


}
